package com.yanqu.road.logic.bussiness.activity;

import com.yanqu.road.entity.activity.tonbingchannel.config.*;
import com.yanqu.road.entity.activity.tonbingchannel.data.*;
import com.yanqu.road.entity.activity.tonbingchannel.join.ChannelTonBingUnionJoin;
import com.yanqu.road.logic.bussiness.DaoHelper;

import java.util.List;
import java.util.Map;

public class ChannelTonBingActivityBusiness {

    // ========== 配置 ==========

    public static Map<Integer, ChannelTonBingBuffTypeConfig> getTonBingBuffTypeConfigMap(int activityId) {
        return DaoHelper.getChannelTonBingConfigDaoImpl().getTonBingBuffTypeConfigLMap(activityId);
    }

    public static Map<Integer,Map<Integer, ChannelTonBingCityTypeConfig>> getTonBingCityTypeConfigMap(int activityId) {
        return DaoHelper.getChannelTonBingConfigDaoImpl().getTonBingCityTypeConfigMap(activityId);
    }

    public static Map<Integer,Map<Integer, ChannelTonBingCityConfig>> getTonBingCityConfigMap(int activityId) {
        return DaoHelper.getChannelTonBingConfigDaoImpl().getTonBingCityConfigMap(activityId);
    }

    public static Map<Integer, ChannelTonBingNpcEventConfig> getTonBingNpcEventConfigMap(int activityId) {
        return DaoHelper.getChannelTonBingConfigDaoImpl().getTonBingNpcEventConfigMap(activityId);
    }

    public static Map<Integer, Map<Integer, ChannelTonBingTitleConfig>> getTonBingTitleConfigMap(int activityId) {
        return DaoHelper.getChannelTonBingConfigDaoImpl().getTonBingTitleConfigMap(activityId);
    }

    public static Map<Integer, ChannelTonBingBuffTypeConfig> getTonBingBuffTypeConfigMap(String dbParam, int activityId) {
        return DaoHelper.getTempChannelTonBingConfigDaoImpl(dbParam).getTonBingBuffTypeConfigMap(activityId);
    }

    public static Map<Integer,Map<Integer, ChannelTonBingCityConfig>> getTonBingCityConfigMap(String dbParam, int activityId) {
        return DaoHelper.getTempChannelTonBingConfigDaoImpl(dbParam).getTonBingCityConfigMap(activityId);
    }

    public static  Map<Integer,Map<Integer, ChannelTonBingCityTypeConfig>> getTonBingCityTypeConfigMap(String dbParam, int activityId) {
        return DaoHelper.getTempChannelTonBingConfigDaoImpl(dbParam).getTonBingCityTypeConfigMap(activityId);
    }

    public static  Map<Integer, ChannelTonBingNpcEventConfig> getTonBingNpcEventConfigMap(String dbParam, int activityId) {
        return DaoHelper.getTempChannelTonBingConfigDaoImpl(dbParam).getTonBingNpcEventConfigMap(activityId);
    }

    public static Map<Integer, Map<Integer, ChannelTonBingTitleConfig>> getTonBingTitleConfigMap(String dbParam, int activityId) {
        return DaoHelper.getTempChannelTonBingConfigDaoImpl(dbParam).getTonBingTitleConfigMap(activityId);
    }

    // ========== 数据 ==========


    public static TonBingUserChannelData getTonBingUserChannelData(int activityId, long userId) {
        return DaoHelper.getTonBingUserChannelDataDaoImpl().getTonBingUserChannelData(activityId,userId);
    }

    public static boolean addTonBingUserChannelData(TonBingUserChannelData data) {
        return DaoHelper.getTonBingUserChannelDataDaoImpl().add(data);
    }

    public static boolean updateTonBingUserChannelData(TonBingUserChannelData data) {
        return DaoHelper.getTonBingUserChannelDataDaoImpl().update(data);
    }


    public static Map<Integer, ChannelTonBingData> getChannelTonBingDataMap(int activityId) {
        return DaoHelper.getChannelTonBingDataDaoImpl().getChannelTonBingDataMap(activityId);
    }

    public static int getMaxMatchId(int activityId) {
        return DaoHelper.getChannelTonBingDataDaoImpl().getMaxMatchId(activityId);
    }



    public static boolean addChannelTonBingData(ChannelTonBingData data) {
        return DaoHelper.getChannelTonBingDataDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingData(ChannelTonBingData data) {
        return DaoHelper.getChannelTonBingDataDaoImpl().update(data);
    }

    public static ChannelTonBingDataMain getChannelTonBingDataMain(int activityId) {
        return DaoHelper.getChannelTonBingDataMainDaoImpl().getChannelTonBingDataMain(activityId);
    }

    public static boolean addChannelTonBingDataMain(ChannelTonBingDataMain data) {
        return DaoHelper.getChannelTonBingDataMainDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingDataMain(ChannelTonBingDataMain data) {
        return DaoHelper.getChannelTonBingDataMainDaoImpl().update(data);
    }

    public static Map<Integer,Map<Integer, ChannelTonBingCampMatchData>> getChannelTonBingCampMatchDataMap(int activityId) {
        return DaoHelper.getChannelTonBingCampMatchDataDaoImpl().getChannelTonBingCampMatchDataMap(activityId);
    }

    public static boolean addChannelTonBingCampMatchData(ChannelTonBingCampMatchData data) {
        return DaoHelper.getChannelTonBingCampMatchDataDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingCampMatchData(ChannelTonBingCampMatchData data) {
        return DaoHelper.getChannelTonBingCampMatchDataDaoImpl().update(data);
    }

    public static Map<Integer, ChannelTonBingCampData> getChannelTonBingCampDataMap(int activityId) {
        return DaoHelper.getChannelTonBingCampDataDaoImpl().getChannelTonBingCampDataMap(activityId);
    }

    public static boolean addChannelTonBingCampData(ChannelTonBingCampData data) {
        return DaoHelper.getChannelTonBingCampDataDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingCampData(ChannelTonBingCampData data) {
        return DaoHelper.getChannelTonBingCampDataDaoImpl().update(data);
    }

    public static Map<String, ChannelTonBingUnionJoin> getChannelTonBingUnionJoinMap(int activityId) {
        return DaoHelper.getChannelTonBingUnionJoinDaoImpl().getChannelTonBingUnionJoinMap(activityId);
    }

    public static boolean addChannelTonBingUnionJoin(ChannelTonBingUnionJoin data) {
        return DaoHelper.getChannelTonBingUnionJoinDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingUnionJoin(ChannelTonBingUnionJoin data) {
        return DaoHelper.getChannelTonBingUnionJoinDaoImpl().update(data);
    }

    public static Map<Long, ChannelTonBingUserData> getChannelTonBingUserDataMap(int activityId) {
        return DaoHelper.getChannelTonBingUserDataDaoImpl().getChannelTonBingUserDataMap(activityId);
    }

    public static boolean addChannelTonBingUserData(ChannelTonBingUserData data) {
        return DaoHelper.getChannelTonBingUserDataDaoImpl().add(data);
    }

    public static boolean updateChannelTonBingUserData(ChannelTonBingUserData data) {
        return DaoHelper.getChannelTonBingUserDataDaoImpl().update(data);
    }

    public static boolean addCityReportList(List<ChannelTonBingCityWarReport> reportList){
        return DaoHelper.getChannelTonBingReportDaoImpl().addCityReportList(reportList);
    }

    public static boolean addUserReportList(List<ChannelTonBingUserWarReport> reportList){
        return DaoHelper.getChannelTonBingReportDaoImpl().addUserReportList(reportList);
    }

    public static Map<Integer,List<ChannelTonBingCityWarReport>> getCityReportListMap(int activityId){
        return DaoHelper.getChannelTonBingReportDaoImpl().getCityReportListMap(activityId);
    }

    public static Map<Integer,List<ChannelTonBingCityWarReport>> getCityReportMap(int activityId){
        return DaoHelper.getChannelTonBingReportDaoImpl().getCityReportMap(activityId);
    }

    public static Map<Integer,List<ChannelTonBingUserWarReport>> getUserReportListMap(int activityId){
        return DaoHelper.getChannelTonBingReportDaoImpl().getUserReportListMap(activityId);
    }

}
